import request from '@/utils/request'
import type {DataType,ChoisesType, interestData}  from './resourceType'

// 1.请求推荐--视频列表 column=recommend
export const reqRecommend = (pageNum:number,pageSize:number)=>{
    return request.get<null,DataType>(`/moment/moments/rec/default?&pageNum=${pageNum}&pageSize=${pageSize}`)
}


// 2. 请求作品---综合榜 column=original
export const reqIntegrated = (pageNum:number,pageSize:number)=>{
    return request.get<null,DataType>( `/moment/moments/collect/original/integrated?&pageNum=${pageNum}&pageSize=${pageSize}`)
}

// 3. 请求作品--热练榜
export const reqPopTraining = (pageNum:number,pageSize:number)=>{
    return request.get<null,DataType>(`/moment/moments/collect/original/popTraining?&pageNum=${pageNum}&pageSize=${pageSize}`)
}

// 4. 请求作品--新锐榜单/最新
export const reqNewcomer = (pageNum:number,pageSize:number)=>{
    return request.get<null,DataType>(`/moment/moments/collect/original/newcomer?&pageNum=${pageNum}&pageSize=${pageSize}`)
}

// 5. 获取可隐藏的动态条件
export const reqPropertiesFilter=()=>{
    return request.get<null,ChoisesType>(`/moment/properties/filter/original`)
}

// 6. 多条件过滤
export const reqLastest = (pageNum:number,pageSize:number,filterInfo:any)=>{
    return request.post<null, DataType>(`/moment/moments/collect/original/lastest?&pageNum=${pageNum}&pageSize=${pageSize}`,{filterInfo})
}

// 7.选择兴趣技能列表
export const reqInterestList = (pageNum:number,pageSize:number)=>{
        return request.get<null,interestData>(`avocation/avocations/rec/user?&pageNum=${pageNum}&pageSize=${pageSize}`)
    }
